-
Notifications
You must be signed in to change notification settings - Fork 332
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
MercAutoEquip #1141
base: master
Are you sure you want to change the base?
MercAutoEquip #1141
Conversation
add support for account with more than 8 chars add flash for various move/town tasks to alleviate desync issues fix item color handling for non-standard string tables fix bug with runeword base check
GameAction, MuleLogger, Misc -Add missing var declaration from last commit
Set previous only when result is set. Now checks area id only when result is false for better performance.
Fix Storage.IsLocked error by checking for both parent type and gid
mercautoequip
Create MercAutoEquipExample.nip
return false; | ||
} | ||
|
||
if (typeof bodyLocMerc === "number") { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
refactor idea, remove this "number" check and assign as array to begin with:
bodyLocMerc = [5]; etc
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is need it as its need it for player auto equip. Im wrong?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
break;
default:
return false;
}
if (typeof bodyLoc === "number") {
bodyLoc = [bodyLoc];
}
return bodyLoc;
},
this one is for the player
d2bs/kolbot/libs/common/Misc.js
Outdated
classid = items[0].classid; | ||
|
||
if (this.equipMerc(items[0], bodyLoc[j])) { | ||
Misc.logItem("Equipped Merc", me.getItem(-1, -1, gid)); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
run the eslint or jslint to fix any formatting issues like this
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I fix it
|
||
for (i = 0; i < 3; i += 1) { | ||
if (item.toCursor()) { | ||
var gid = item.gid; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
don't think this is needed since you commented out logitem, consider removing this code and related comments
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I remove the // commented
} | ||
} | ||
} | ||
return true; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
add newline before return
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
fix it
d2bs/kolbot/libs/common/Misc.js
Outdated
bodyLocMerc = 3; | ||
|
||
break; | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
remove newline here
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
fix it
@noah- as you requested all in one patch